﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows.Data;

namespace for7raid.vkPlayer
{
    public class SelectedItemsMoreOneConverter: IMultiValueConverter
    {
        

        public object Convert(object[] values, Type targetType, object parameter, System.Globalization.CultureInfo culture)
        {
            var items = values[0] as ICollection<MediaItem>;
            return items != null && items.Where(i => PlayerViewModel.GetSelected(i)).Count() > 1;
        }

        public object[] ConvertBack(object value, Type[] targetTypes, object parameter, System.Globalization.CultureInfo culture)
        {
            throw new NotImplementedException();
        }
    }
}
